home *** CD-ROM | disk | FTP | other *** search
/ Disc to the Future 2 / Disc to the Future Part II Programmer's Reference (Wayzata Technology)(6013)(1992).bin / MAC / THINKC / 3_0 / MTN_RENA / MTN_RENA.C1 < prev   
Text File  |  1990-12-08  |  3KB  |  67 lines

  1. /*
  2.  
  3. Don╒t you hate it that they changed the format of the Mac Tech Notes? It 
  4. screws up the numerical listing in the SF dialog, which means you have 
  5. to hunt for the darn file. Is it ╥TN.139.╙ or ╥139╙? Who can tell?
  6.  
  7. MTN renamer is a no-frills solution to that incredibly irritating 
  8. problem. Basically, MTN renamer converts all the ╥nnn╙-format technotes 
  9. to the new ╥TN.nnn.╙-format. Suddenly, ╥000 About Mac TNs 10/90╙ becomes 
  10. ╥TN.000.About╩Mac╩TNs 10/90╙.
  11.  
  12. To use it, just launch it. MTNR prompts you for the directory where it 
  13. should look for those old files, and goes off to change all of them.
  14.  
  15. Program notes:
  16.  
  17. If a filename becomes longer than 31 characters, it will be cut
  18.  to 31 characters.
  19.  
  20. There╒s really no error checking besides the bare minimum. If a name 
  21. can╒t be changed, the program skips it and goes on. All the files that 
  22. the program had problems with will, of course, be at the top of the list 
  23. when you view the folder by name (they╒ll still be in the old format, so 
  24. will ╘float╒ to the top).
  25.  
  26. It takes a while if there are a lot of files, but it╒s still faster than 
  27. doing it by hand.
  28.  
  29. The program will run under MultiFinder, but grabs control until it╒s 
  30. finished. If the darn thing won╒t run, increase it╒s partition. It╒s set 
  31. so small (35K) that any inits that fool with the SF dialogs may eat up 
  32. all of it╒s memory.
  33.  
  34. What's new:
  35.  
  36. I figured out why the ioFDirIndex kept skipping files. It seems that any
  37. change to a file pushes that file to the bottom of the file list, while
  38. at the same time shifting all the other files up by 1. Thus, MTNR 1.01
  39. only makes 1 pass through the folder/disk, instead of numFiles/4+1 passes.
  40. Speeds it up quite a bit.
  41.  
  42. General notes:
  43.  
  44. The commented source code is included.
  45.  
  46. The program is FISHware, which means that you should send whatever you 
  47. want to me if you use the program and find it useful. I╒m still waiting 
  48. for a check for $500, 000, a BMW, or a pipe bomb, not necessarily in 
  49. that order.
  50.  
  51. I will not be held responsible for any damage, etc. caused to you, your 
  52. computer, your files, etc. The program is given away ╘as is╒, and will 
  53. function as described above with the limitations described above. 
  54. Basically, please don╒t sue me. There╒s no reason that I can think of 
  55. for the program to do anything that it╒s not supposed to. Heck, it╒s so 
  56. darn simple I can╒t see where there could be any problems. But if you 
  57. have any, drop me a line at any of the addresses below:
  58.  
  59. CIS: 70365,1426
  60. GEnie: M.Veloso
  61. USmail:
  62.     Manuel Veloso
  63.     9 High Rock Way #3
  64.     Brighton, MA 02135
  65.     
  66. */
  67.